﻿using System;
using System.Net;
using System.Reflection;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;

namespace Lottery.Client.SL.Util
{
    public class Debug
    {
        public static string ShowProperty(object o)
        {
            if (o == null)
                return string.Empty;
            var s = new StringBuilder();
            Type type = o.GetType();
            PropertyInfo[] props = type.GetProperties();

            foreach (var p in props)
            {
                s.Append(p.Name + " : " + p.GetValue(o, null) + "\r\n");
            }
            return s.ToString();
        }
    }
}
